package com.cupster.func_db_dbflow5.db_main.table;

import com.cupster.func_db_dbflow5.DBManager;
import com.cupster.func_db_dbflow5.db_main.AppDB;

@Table(database = AppDB.class ,name = "user")
public class User extends BaseModel {

    @PrimaryKey(autoincrement = true)
    private long id ;

    @Column
    private String account ;

    @Column
    private String password;

    @Column
    private String name;

    @Column
    private int age;

    @Column
    private long loginMill;

    public long insert(){
        return super.insert(DBManager.getAppDB());
    }
    public boolean delete(){
        return super.delete(DBManager.getAppDB());
    }
    public boolean update(){
        return super.update(DBManager.getAppDB());
    }

    public long getId() {
        return id;
    }

    public void setId(long id) {
        this.id = id;
    }

    public String getAccount() {
        return account;
    }

    public void setAccount(String account) {
        this.account = account;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public long getLoginMill() {
        return loginMill;
    }

    public void setLoginMill(long loginMill) {
        this.loginMill = loginMill;
    }

}
